


import React  from 'react'



let arr=['node','vue','react']

let  obj={
    firstName:'武当山',
    lastName:'张三丰'
}


function  formatName(data) {
    return data.firstName+data.lastName
}

export  default  class  List extends React.Component {
      render() {

        return(
            <div>
                <h2> List组件</h2>

                <ul>
               
                    
                    {

                        arr.map(v=><li key={v}>  {v} </li>)
                    }
                    
                </ul>

                <div>  {obj.firstName+obj.lastName}</div>

                <div>{formatName(obj)}</div>
            </div>
        )
      }
}